﻿<%@tag language="java" pageEncoding="UTF-8" %>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@taglib prefix="tags" tagdir="/WEB-INF/tags" %>
<%@attribute name="menu" required="true" rtexprvalue="true" type="com.tangtang.core.tree.Tree<com.tangtang.security.view.model.SysViewResource>" %>
<c:if test="${menu.value.active == null || menu.value.active == false}">
    <li class="">
</c:if>
<c:if test="${menu.value.active == true}">
    <li class="active">
</c:if>
<c:if test="${empty menu.value.resourceUrl}">
    <a href="javascript:;">
</c:if>
<c:if test="${not empty menu.value.resourceUrl}">
    <a href="${pageContext.request.contextPath}${menu.value.resourceUrl}">
</c:if>
<i class="${menu.value.resourceIcon}"></i>
<span class="title">${menu.value.resourceMenuName}</span>
<c:if test="${not empty menu.children}">
    <span class="fa arrow"></span>
</c:if>
</a>
<c:if test="${not empty menu.children}">
    <ul class="sub-menu">
        <c:forEach var="menu" items="${menu.children}">
            <tags:recursivemenu menu="${menu}"></tags:recursivemenu>
        </c:forEach>
    </ul>
</c:if>
</li>